package com.itheima.job;

import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collection;

public class Test07 {
    public static void main(String[] args) {
        ArrayList<String> al = new ArrayList<>();
        method(al,"sss");

        ArrayList<int[]> array = new ArrayList<>();
        method(array,new int[]{1,2,3});
        method(array,new int[]{4,5,6});
        for (int[] ints : array) {
            for (int anInt : ints) {
                System.out.println(anInt);
            }
        }

    }
    public static <E> void method(Collection<E> c,E e){
        c.add(e);
    }
}
